#include<bits/stdc++.h>
#define int long long

using namespace std;

string ret;
string s;
int x, y, gs = 0;
int n;

void dfs(int len, string t, int xx, int yy) {
	if(len == n) {
		if(xx == x && yy == y) {
			ret = t;
			//cout << "ret = " << ret << endl;
			gs ++ ;	
		}
		return;
	}
	if(s[len] == 'U') {
		dfs(len + 1, t, xx, yy);
		dfs(len + 1, t + s[len], xx + 1, yy);
	} else if(s[len] == 'D') {
		dfs(len + 1, t, xx, yy);
		dfs(len + 1, t + s[len], xx - 1, yy);
	} else if(s[len] == 'L') {
		dfs(len + 1, t, xx, yy);
		dfs(len + 1, t + s[len], xx, yy - 1);
	} else {
		dfs(len + 1, t, xx, yy);
		dfs(len + 1, t + s[len], xx, yy + 1);
	}
}

signed main() {
	int t;
	cin >> t;
	while(t -- ) {
		ret = "";
		gs = 0;
		cin >> n >> x >> y;
		cin >> s;
		string p = "";
		dfs(0, p, 0, 0 );
		
		if(ret == "") {
			cout << "NO" << endl;
		} else {
			cout << "YES " << ret << " " << gs << endl; 
		}
	}	
	return 0;
}

